home *** CD-ROM | disk | FTP | other *** search
/ Software Vault: The Games Collection 1 / software vault.zip / software vault / CDR09 / CEDTUT.ZIP / UTILS.TXT < prev   
Text File  |  1991-10-18  |  38KB  |  941 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.  
  13.  
  14.  
  15.  
  16.                      Utilities for CHESSEDT.EXE
  17.                
  18.                            Andrew Kochera
  19.  
  20.  
  21.  
  22.  
  23.  
  24.  
  25.  
  26.  
  27.  
  28.  
  29.  
  30.  
  31.  
  32.  
  33.  
  34.  
  35. All programs in this package are copyright 1991 by Andrew
  36. Kochera.
  37.  
  38. CHESSEDT is copyright by Stephen M. Wharry.  CHESSEDT is
  39. shareware.
  40.  
  41. NICBASE is a trademark of Interchess.
  42.  
  43. TurboBasic is a trademark of Borland International, Inc.
  44.  
  45. The programs in this package are Freeware; you may copy, use, and
  46. distribute these programs without charge.  However, if
  47. distributed, they must be unchanged and complete.
  48.  
  49. WAIVER:  the author of these programs accepts no liability or
  50. responsibility for the manner in which these programs are used,
  51. and will not be responsible for damages, monetary or otherwise,
  52. resulting from the use or misuse of these programs.
  53.  
  54.  
  55. I. Introduction
  56.      Stephen Wharry's CHESSEDT program is primarily designed for
  57. use by the postal player.  It's storage, retrieval, and editing
  58. features are quite well designed for this purpose; indeed, its
  59. popularity on Chess bulletin boards is a tribute to its inspired
  60. design.  However, it lacks many of the features that might make
  61. it a full fledged database, such as an opening key and
  62. sophisticated search routines.  The following programs are
  63. intended to bolster CHESSEDT's database abilities, though they
  64. are by no means as clever, fast, or exhaustive as commercial
  65. database programs.
  66.      There are 6 programs in this package:
  67.      
  68.      UTILS.TXT             this documentation
  69.      AUTOKEY.EXE           opening key program
  70.      OPENING.DAT           opening key database
  71.      FINDGAME.EXE          search/print game program
  72.      EXTRACT.EXE           pre-extraction program
  73.      FLNM.EXE              multiple game file rename utility
  74.  
  75.      In addition, you may find a READ.ME file which contains
  76. notes on the current release version.
  77.  
  78.      Finally, I should emphasize that although these programs are
  79. Freeware, Stephen Wharry's CHESSEDT program is not.  It is
  80. shareware and may be found on many BBS's, especially those with a
  81. chess conference.  If you decide that you like CHESSEDT, and
  82. continue to use it, please register it with Mr. Wharry at the
  83. address provided in his manual.  In return, you will be provided
  84. with the most recent updates and have the satisfaction of knowing
  85. that you have supported the concept of shareware.
  86.  
  87. II. Using CHESSEDT as a Database
  88.      As a modem user, I have benefited from the wealth of chess
  89. ASCII files available on various networks.  Over the past year, I
  90. have collected virtually thousands of chess games from famous
  91. players and events, all by logging on to some of my favorite
  92. computer bulletin boards.  Naturally, having chess games in text
  93. form is very useful; you can set up your chess board and play
  94. through the games.  This is both entertaining and educational. 
  95. However, after several games it also becomes tedious to continue
  96. setting up the board and moving pieces by hand.
  97.      An obvious answer to this problem is to buy a program which
  98. can read ASCII (text) chess games, and display them graphically
  99. on the computer screen.  Not only does it make game review
  100. easier, but you can also take advantage of the computer's
  101. abilities to search through collections of games using various
  102. criteria.  The best shareware program I have seen for this
  103. purpose on computer networks is Stephen Wharry's CHESSEDT, which
  104. was originally designed for postal use.  However, for managing
  105. large numbers of games, additional file management abilities and
  106. search criteria are desirable.
  107.      For instance, to import a game from a text file, CHESSEDT
  108. requires that the user format the text file with certain
  109. delimiters (eg, 'bg' 'eg' 'ba') so that the program will know
  110. where a game begins and ends.  In a very large text file of chess
  111. games, this can be tiring.  Why not try to develop a program
  112. which will automatically insert these delimiters?  To be sure, it
  113. is no easy task, since there are many formats that chess games
  114. are recorded in.  But some formats seem more common than others,
  115. and I have written a pre-extraction utility to help insert
  116. delimiters to those common type ASCII chess files.  This speeds
  117. up extraction of large quantities of games.
  118.      Also, if a user wishes to create an opening database, it
  119. would be nice to have a program which will automatically read in
  120. a range of CHESSEDT game files and key their openings.  To that
  121. end, I have written a simple AUTOKEY utility; once game files are
  122. keyed, openings may be searched by name.
  123.      CHESSEDT already has an excellent search game utility.  The
  124. user can search a range of files by player's names, tournament,
  125. date, etc.  The version of CHESSEDT I currently use searches text
  126. by looking for a match on the left hand side of the string, ie,
  127. if you search for "Bobby" you will find games that have "Bobby
  128. Fischer" but not necessarily games that have "Fischer, Bobby".  I
  129. have here included a utility which will search for occurence in a
  130. string regardless of the position within that string.  In
  131. addition, this search utility can also search for an opening
  132. string and print out matching games in a variety of common
  133. formats.
  134.      Finally, if you are going to store a large number of games,
  135. one must be prepared to deal with your system's Disk Operating
  136. System (DOS).  CHESSEDT game files each contain one game;
  137. therefore, if you have 1000 games, you must have 1000 files on
  138. your disk.  Please note that the root directory on a floppy disk
  139. can only hold a hundred or so files.  To store more, create a
  140. subdirectory for your game files.  If you are using a hard disk
  141. to store game files, another problem arises.  Most hard disks
  142. access files according to a cluster, which can be defined
  143. anywhere from 512 bytes to 4000 bytes or more.  Regardless of the
  144. size of your game file, it will effectively take a full cluster
  145. of storage space, since there can be only one file per cluster. 
  146. So even if your game file is 600 bytes, it may require around
  147. 2000 bytes of storage, depending on the cluster size of your hard
  148. drive.  Motto: watch your disk space carefully, or store your
  149. games on floppies, which usually have a cluster size of only 1024
  150. bytes.  Floppies are slower, but more space efficient when
  151. dealing with large numbers of very small files.
  152.      With such a large number of game files, you may wish to
  153. rename them according to their opening for easy retrieval, and to
  154. sort them into subdirectories on the basis of their opening name.
  155. Perhaps you wish to renumber them.  I have included a few
  156. renaming utilities to help with this.
  157.      Finally, please note that if you are REALLY into collecting
  158. HUGE numbers of chess games, even these utilities cannot keep
  159. pace.  Such a chess hobbyist should definitely think about a
  160. commercial chess database.
  161.  
  162.  
  163.  
  164.  
  165.  
  166. III. AUTOKEY.EXE
  167.  
  168. A. Overview
  169.      The AUTOKEY utility reads in CHESSEDT game files, and will
  170. search through a predefined database of opening codes until a
  171. match is found.  The search method is textual, rather than
  172. positional; therefore, it is not as accurate as other methods. 
  173. However, the user should find the performance surprisingly
  174. accurate in most situations.  I have used this utility to key
  175. several thousand games with a reasonable degree of precision.     
  176. Please note that this utility will *only* work with short
  177. algebraic chess notation, ie e4 Nf6, rather than e2-e4 g8-f6,
  178. etc.
  179.      Further note than the program can catch simple
  180. transpositions.  The order of the moves are irrelevent.  To
  181. AUTOKEY, the following are identical:
  182.  
  183.      1.e4 c6 2.d4 d5 3.Nc3 Nf6
  184.     
  185.      1.Nc3 c6 2.d4 d5 3.e4 Nf6
  186.  
  187.  
  188. B. How it works
  189.      AUTOKEY consists of two files.  The first is the program
  190. AUTOKEY.EXE, which contains the program executable code.  It was
  191. written in Turbobasic, of all things, and is not the paragon of
  192. speed.  However, I have noticed that computers installed with a
  193. math coprocessor, or computers with 25Mhz or higher, are
  194. reasonably fast for small to mid-sized applications.  If you are
  195. going to key many hundreds of game files (or thousands!) on an
  196. old XT, you should plan to leave the computer on overnight.  It
  197. is not the author's contention that this program performs nearly
  198. as fast as commercial database keys.
  199.      The companion file is OPENING.DAT, which is the catalogue of
  200. opening systems which AUTOKEY can recognize.  OPENING.DAT is
  201. nothing more than a text file, which contains opening names and
  202. corresponding moves, one after the other.  If the user wishes,
  203. he/she may add or change the openings found in this file by using
  204. a text editor or word processor which can save to raw ASCII. 
  205. Please make sure, if changing OPENING.DAT, that your word
  206. processor does not leave special codes in the saved text.
  207.      In order for AUTOKEY.EXE to properly read OPENING.DAT, the
  208. following rules apply:
  209.  
  210.      1. There must be no blank lines anywhere in the file
  211.      2. The opening entry must contain two lines; firstly,
  212.           the name of the opening (preferably under 40
  213.           characters, but up to 80).  The second line 
  214.           will contain the moves of the opening.
  215.           Notice that this means opening names are
  216.           on odd numbered lines, and moves on even
  217.           numbered lines.
  218.      3. The opening moves must be in condensed short 
  219.           algebraic.  (see section III D for what I mean
  220.           by this admittedly confusing term)
  221.      4. There should be no blank spaces at the beginning
  222.           or end of any line.
  223.      5. Do not include move numbers, ie write 1.e4 c6 2.d4
  224.           as e4 c6 d4
  225.  
  226.      In the current version, AUTOKEY can read up to 500 openings,
  227. and already has around 245 in the OPENING.DAT file.
  228.  
  229.  
  230. C. Using AUTOKEY
  231.      To reiterate:  AUTOKEY.EXE can only read short algebraic
  232. chess notation (ie, e4, Nf3).  This has become the norm in most
  233. magazines and BBS chess ASCII files.  However, there are still
  234. some sources which use old descriptive notation (P-K4, N-KB3,etc);
  235. AUTOKEY cannot recognize those.  And although AUTOKEY reads 
  236. short algebraic game files, any additions or changes to the
  237. provided OPENING.DAT file must be in condensed short algebraic.
  238. But if you don't change the OPENING.DAT file, and you probably
  239. won't, that's no problem.
  240.     
  241.      Make sure both AUTOKEY.EXE and OPENING.DAT are in the
  242. current directory.  Now, at the dos prompt type 'AUTOKEY' and hit
  243. your return key.  The program will load and execute.  For the
  244. next several moments, depending on the speed of your computer,
  245. the program will read in the openings and set up an internal
  246. array.  Once this has been completed, the computer will prompt
  247. you for the directory that contains the CHESSEDT games you want
  248. keyed.  Be sure to write this as you would in any ordinary Dos
  249. application, including the drive and backslashes.  For example:
  250.  
  251.    c:\gamfiles\
  252.  
  253.       or
  254.  
  255.    d:\chess\games\
  256.  
  257.      (Please include the final backslash)
  258.      Now hit return.
  259.      The computer now asks for a filespec.  That means it wants
  260. you to describe that name(s) of the game file(s) you want keyed. 
  261. I use the possible plural since the program *does* accept Dos
  262. wildcards.  Here are some examples:
  263.  
  264.    BRAD0291.GAM         (to key a single game of that file name)  
  265.    US91*.GAM            (to key all games which have US91 in the    
  266.                          first four characters of the file name)
  267.  
  268.      Hit return again.
  269.  
  270.      Now the tricky part.  The program will ask you for the
  271. number of iterations you require, from 0 to 4.  Obviously, we
  272. must take a moment to describe what an 'iteration' means in the
  273. context of this program!
  274.      The number of iterations determines how deep in the game
  275. file AUTOKEY will search for an opening.  On the first pass,
  276. AUTOKEY will only search as deeply as the current opening being
  277. considered; ie, if AUTOKEY is currently considering e4 c6, it
  278. will first search only the first two ply (one move) of the game
  279. file.  It will do so for each opening in the database described
  280. by OPENING.DAT.
  281.      Now, if there are no opening matches larger than 2 ply,
  282. AUTOKEY must decide whether to search further into the game. 
  283. This is where the term iteration comes in.  If there are no
  284. matches in the first pass, and iteration is set to one, AUTOKEY
  285. will go back and try again to key the game, THIS TIME SEARCHING
  286. ONE EXTRA PLY INTO THE GAME FILE.  Notice if there is an exact
  287. match on the first pass (iteration 0), and this match is greater
  288. than 2 ply, the game will be keyed and the program will look no
  289. further.
  290.      Up to four iterations may be selected; that is, for
  291. particularly difficult games, AUTOKEY will search up to 4 ply
  292. into the game beyond the number of moves in openings searched
  293. for.  Then it will just give up; "call it irregular for heavens
  294. sake!", AUTOKEY seems to be saying.
  295.      The purpose of the iteration ability was to make it possible
  296. to catch opening transpositions which include an odd move or two.
  297. The trade off is that AUTOKEY may start to recognize more than
  298. one good opening match, and possibly some inferior matches as
  299. well.
  300.      An iteration setting of 2 is quite adequate.
  301.  
  302.      Once you have chosen the number of iterations, hit return
  303. and the program will begin.  The progress is shown on the screen.
  304. Each game file name is printed as it is considered, and beneath
  305. it are any matches that are found.  AUTOKEY will attempt to find
  306. the best match as it continues its work, so a game which is a Ruy
  307. Lopez will first be classified as an e-pawn opening, then a
  308. double kings pawn opening, then a Ruy Lopez, and then (if
  309. possible) the particular Ruy Lopez variation. 
  310.  
  311.  
  312. D. Short Algebraic
  313.      What do I mean by condensed short algebraic?
  314.  
  315.      Well, short algebraic consists of the piece followed by
  316. destination square. IE, Nf3 or Bc4.  Pawns are simply written as
  317. the destination square, ie e4 or d4.  Captures include an 'x',
  318. such as Nxf3 or (in the case of a pawn) cxd4.
  319.  
  320.      In condensed short notation, please exclude the 'x' during a
  321. capture.  Also exclude the row number in a pawn capture.  In
  322. condensed short notation, the prior example would look like Nf3
  323. and cd.  
  324.      Also, do not include notational commentary, such as ! or ?
  325. in the opening database.  These characters are fine in the game
  326. file, though; AUTOKEY will ignore them in its search.
  327.  
  328.  
  329.  
  330. IV. FINDGAME.EXE
  331.  
  332. A. Overview
  333.      FINDGAME.EXE will search game files according to a variety
  334. of criteria, which may be used in combination.  For instance, you
  335. may search for all games by a certain player and year, and even
  336. include an opening search string if you are trying to track down
  337. a specific game from a large number of files.  Once found, the
  338. games which match the search criteria may be listed in a variety
  339. of ways and saved to a text file.  This text file may later be
  340. sent to a printer, or if the user has chosen the print game
  341. option, the file may be reviewed within CHESSEDT using the
  342. Document view routine.
  343.  
  344. B. Using FINDGAME
  345.      Go into the directory which contains the FINDGAME.EXE file,
  346. and type FINDGAME.  When the program runs, you will see the
  347. screen fill with a variety of choices.  
  348.      First, you must tell the program the directory for it to
  349. search in.  Specify the directory as you would within DOS,
  350. including the drive, colon, and backslash keys.  For instance, to
  351. search the GAME directory in drive a, type "A:\GAME\".  Be sure
  352. to include the last backslash.
  353.      Then the program will ask for a filespec; that is, which
  354. file names you wish to search.  You may use DOS wildcards here. 
  355. Be sure to include ".GAM", ie, "GARY*.GAM" to search all files
  356. which begin with the letters "GARY".
  357.      Next, the program will ask for the target file.  This is the
  358. file that the program will write the results of the search to. 
  359. Write the full file name, including the directory that you want
  360. it to be sent to.  For example, "b:\CHESS\RESULTS.TXT" will send
  361. any matching results to a file called "RESULTS.TXT" in the
  362. directory called "CHESS" on drive "b:".
  363.      As with any DOS filenames, be sure to be accurate when
  364. entering the above options, or an error may occur.  So before
  365. sending the results to the "CHESS" directory, make sure that the
  366. directory exists!
  367.  
  368.      The next set of questions concerns the search criteria.  Any
  369. or all of these options may be left blank.  Opening, Player,
  370. Tournament, Score, and Date are easy enough.  Just type in the
  371. particular string you are looking for.  After the player option,
  372. you have a choice of searching for that player as White, Black,
  373. or Either (default).  
  374.      For instance, if you are searching for all the games in
  375. which Karpov played, type "Karpov" at the Player prompt, and then
  376. select 'E' (for either white or black).  You may include an
  377. opening like "Sic", to search for Karpov's Sicilian games.
  378.      Notice that FINDGAME.EXE searches for occurence, regardless
  379. of the position; that is, typing "Ka" at the Player prompt will
  380. find games which have "Anatoly Karpov", "Karpov, Anatoly" or even
  381. "Gary Kasparov" listed as a player.
  382.      The last search criteria, Opening String, can be used to
  383. search for a particular opening string.  To find games which
  384. begin with the moves 1.e4 c6 2.d4 Bf5, type the moves without the
  385. move numbers.  That is, type "e4 c6 d4 Bf5" and hit return.  If
  386. you decide to search for an opening string, you will also be
  387. asked for the number of iterations.  See the AUTOKEY section for
  388. an explanation of this.
  389.  
  390.      The last questions simply ask how you want the results
  391. printed to the file.  If you only want the file names which
  392. include matches, type "1", return, and then type "Yes" at the
  393. "Include file name" prompt.  Alternatively, you may wish to print
  394. the complete games, so you might chose options 3 or 4.  
  395.      Options 3 and 4 allow you to print the entire game,
  396. including the heading and result.  The only difference between
  397. these two options is that #4 (Format B) includes the opening
  398. name, and #3 (Format A) does not.
  399.  
  400.  
  401.      If the choices seem bewildering, a little practice will
  402. quickly serve to clarify things.  Choose various options to get
  403. accustomed to the them.
  404.  
  405.  
  406. V. EXTRACT.EXE - Extraction Utility
  407.  
  408. A. Overview
  409.      Many chess bulletin boards contain a number of chess game
  410. collections which are usually kept in plain ASCII text files.  It
  411. is instructional to download these collections and play over the
  412. games at your leisure.  If you extract these games to CHESSEDT
  413. format, you can use CHESSEDT to categorize, edit,and view those
  414. games.  The problem is that there is sometimes a bit of work
  415. necessary to get the text file into a form that CHESSEDT can
  416. understand.  EXTRACT can diminish, but probably will not
  417. eliminate, the work required to input a large number of ASCII
  418. chess games from a text file to CHESSEDT format.     
  419.      Steve Wharry's CHESSEDT provides a utility within the
  420. program to extract chess games from plain text files.  First,
  421. however, the user must edit the text files and insert various
  422. delimiters to tell CHESSEDT where games, headings, etc begin and
  423. end.  Even with a good word processor, this can be a tedious
  424. task.  EXTRACT has four options for inputing those delimiters
  425. automatically to a text file.  If a text file contains chess
  426. games which match one of the standard formats that EXTRACT can
  427. recognize, then the process of extracting up to hundreds of games
  428. can be completed in a tiny fraction of the time previously
  429. required.  If the text file you wish to extract games from
  430. presents games in a format EXTRACT cannot recognize, then it is
  431. likely that you can use a few global search/replace functions in
  432. your word processor to alter the text file until EXTRACT is able
  433. to recognize it.
  434.  
  435. B. Preparing the Text File
  436.      In order to use EXTRACT, the file of chess games must:
  437.  
  438.      1) be in ordinary ASCII; that is, it should have no special
  439.         codes.  If you edit the text file with your word
  440.         processor, make sure you save the game as plain ASCII.
  441.         By default, many word processors include special codes
  442.         when saving text, but you will want to over-ride this.
  443.      2) have a blank line both at the beginning and at the end
  444.         of the text file
  445.      3) there must be at least one blank line between chess games
  446.      4) each chess game must have the result immediately at the
  447.         end of the moves, either on the same line as the last
  448.         line of moves, or on the line immediately thereafter
  449.      5) the result should be in the form 1-0, 0-1, or Draw (or
  450.         1/2). Extract cannot recognize 'Win' or 'Mate', since it
  451.         is not smart enough to figure out which player won.
  452.      6) each line of a chess game MUST be flush with the
  453.         left margin; that is, there should be no spaces at the
  454.         beginning of any line in a chess game.
  455.  
  456.      These conditions may seem stringent, however, most chess
  457. text files already meet all six of these requirements.
  458.  
  459.      EXTRACT searches for chess games by searching for results.
  460. For example, when it finds "1-0", it assumes it has found the end
  461. of a game.  Then, it searches backward for the moves and a
  462. heading.  But in reality, EXTRACT can only recognize games if
  463. they appear in one of four formats, which are here referred to as
  464. 'A', 'B', 'C' and 'D'.
  465.      You will probably still need your word processor to make
  466. sure that the games in the text file are in one of these  forms. 
  467. However, most collections of games I've seen on bulletin boards
  468. are close to one of these forms, and a little global
  469. search/replace from a word processor will get things in order.
  470.  
  471.  
  472.  
  473. B.1  FORMAT A
  474.      Format 'A' consists of a heading which contains players'
  475. names and the tournament (which may include a date).  A game in
  476. format 'A' should look as follows:
  477.  
  478. WHITEPLAYER-BLACKPLAYER
  479. TOURNAMENT
  480. 1.e4 c6 2.d4 c6 .....                (or whatever the moves are)
  481. RESULT
  482.  
  483. example:
  484.        
  485. Kasparov,G-Chiburdanidze,M
  486. Baku, 1980
  487. 1.d4 Nf6 2.c4 g6 3.Nc3 Bg7 4.e4 d6 5.Nf3 0-0 6.Be2 e5 7.Be3 Qe7
  488. 8.d5 Ng4 9.Bg5 f6 10.Bh4 h5 11.h3 Nh6 12.Nd2 c5 13.Nf1 Nf7 14.g4
  489. hxg4 15.Bxg4 g5 16.Bxc8 Rxc8 17.Ne3 gxh4 18.Nf5 Qd8 19.Qg4 Ng5
  490. 20.Nxh4 Rc7 21.Nf5 a6 22.h4 Nh7 23.Rg1 Qf8 24.Ke2 Ra7 25.a4 b6
  491. 26.Qh5 Kh8 27.Rg6 Rd7 28.Rag1 Rab7 29.Qg4 Rbc7 30.Rg2 Rb7 31.Kf1
  492. Ra7 32.Kg1 Rf7 33.Ne2 Qc8 34.f4 b5 35.axb5 axb5 36.cxb5 Rab7
  493. 37.h5 Nf8 38.Qh3 Nxg6 39.hxg6+ Kg8 40.gxf7+ Kf8
  494. 1-0
  495.             
  496.  
  497.      If your text file contains chess games in this format, then
  498. you should choose option '1' from the EXTRACT main menu.
  499.  
  500.  
  501.  
  502.  
  503. B.2  FORMAT B
  504.      Format B is the same, except that it reads games which have
  505. the opening listed on a line between the TOURNAMENT line and the
  506. first line of game moves.  That is:
  507.  
  508. WHITEPLAYER-BLACKPLAYER
  509. TOURNAMENT
  510. OPENING
  511. 1.e4 c6 2.d4 c6 .....                (or whatever the moves are)
  512. RESULT
  513.  
  514. example:
  515.        
  516. Kasparov,G-Chiburdanidze,M
  517. Baku, 1980
  518. KIN 01:  King's Indian - Classical
  519. 1.d4 Nf6 2.c4 g6 3.Nc3 Bg7 4.e4 d6 5.Nf3 0-0 6.Be2 e5 7.Be3 Qe7
  520. 8.d5 Ng4 9.Bg5 f6 10.Bh4 h5 11.h3 Nh6 12.Nd2 c5 13.Nf1 Nf7 14.g4
  521. hxg4 15.Bxg4 g5 16.Bxc8 Rxc8 17.Ne3 gxh4 18.Nf5 Qd8 19.Qg4 Ng5
  522. 20.Nxh4 Rc7 21.Nf5 a6 22.h4 Nh7 23.Rg1 Qf8 24.Ke2 Ra7 25.a4 b6
  523. 26.Qh5 Kh8 27.Rg6 Rd7 28.Rag1 Rab7 29.Qg4 Rbc7 30.Rg2 Rb7 31.Kf1
  524. Ra7 32.Kg1 Rf7 33.Ne2 Qc8 34.f4 b5 35.axb5 axb5 36.cxb5 Rab7
  525. 37.h5 Nf8 38.Qh3 Nxg6 39.hxg6+ Kg8 40.gxf7+ Kf8
  526. 1-0
  527.  
  528.  
  529.  
  530.      If your text file contains games in this format, then choose
  531. option '2' from the EXTRACT main menu.
  532.  
  533.  
  534.  
  535. B.3 Format C
  536.      Format C has each player listed, on a separate line, as
  537. white or black.  The words "White:" or "Black:" or "W:" or "B:"
  538. are recognized by extract as player labels.  Then follows the
  539. tournament name, and next an opening label.  After this heading
  540. follow the moves and result.
  541.  
  542.      Some examples of this format are:
  543.  
  544.  
  545. White: Kasparov,G
  546. Black: Chiburdanidze,M
  547. Baku, 1980
  548. KIN 01:  King's Indian - Classical
  549. 1.d4 Nf6 2.c4 g6 3.Nc3 Bg7 4.e4 d6 5.Nf3 0-0 6.Be2 e5 7.Be3 Qe7
  550. 8.d5 Ng4 9.Bg5 f6 10.Bh4 h5 11.h3 Nh6 12.Nd2 c5 13.Nf1 Nf7 14.g4
  551. hxg4 15.Bxg4 g5 16.Bxc8 Rxc8 17.Ne3 gxh4 18.Nf5 Qd8 19.Qg4 Ng5
  552. 20.Nxh4 Rc7 21.Nf5 a6 22.h4 Nh7 23.Rg1 Qf8 24.Ke2 Ra7 25.a4 b6
  553. 26.Qh5 Kh8 27.Rg6 Rd7 28.Rag1 Rab7 29.Qg4 Rbc7 30.Rg2 Rb7 31.Kf1
  554. Ra7 32.Kg1 Rf7 33.Ne2 Qc8 34.f4 b5 35.axb5 axb5 36.cxb5 Rab7
  555. 37.h5 Nf8 38.Qh3 Nxg6 39.hxg6+ Kg8 40.gxf7+ Kf8
  556. 1-0
  557.  
  558.                   - or -
  559.  
  560. W: Kasparov,G
  561. B: Chiburdanidze,M
  562. Baku, 1980
  563. KIN 01:  King's Indian - Classical
  564. 1.d4 Nf6 2.c4 g6 3.Nc3 Bg7 4.e4 d6 5.Nf3 0-0 6.Be2 e5 7.Be3 Qe7
  565. 8.d5 Ng4 9.Bg5 f6 10.Bh4 h5 11.h3 Nh6 12.Nd2 c5 13.Nf1 Nf7 14.g4
  566. hxg4 15.Bxg4 g5 16.Bxc8 Rxc8 17.Ne3 gxh4 18.Nf5 Qd8 19.Qg4 Ng5
  567. 20.Nxh4 Rc7 21.Nf5 a6 22.h4 Nh7 23.Rg1 Qf8 24.Ke2 Ra7 25.a4 b6
  568. 26.Qh5 Kh8 27.Rg6 Rd7 28.Rag1 Rab7 29.Qg4 Rbc7 30.Rg2 Rb7 31.Kf1
  569. Ra7 32.Kg1 Rf7 33.Ne2 Qc8 34.f4 b5 35.axb5 axb5 36.cxb5 Rab7
  570. 37.h5 Nf8 38.Qh3 Nxg6 39.hxg6+ Kg8 40.gxf7+ Kf8
  571. 1-0
  572.  
  573.  
  574.      If your text file contains games in one of these two
  575. formats, then choose option '3' from the EXTRACT main menu.
  576.  
  577.  
  578. B.4 Format D
  579.      Format D has the name of the opening listed on line one
  580. along with (after several spaces) some other notation used to
  581. describe its source.  On the next line come the player names
  582. separated by a dash, and on the third line of the heading is the
  583. tournament.  Then follow the moves and the result.  
  584.      I have noticed that NICBASE often uses this format to output
  585. its games.
  586.  
  587. Example:
  588.  
  589. AB 1.23.4       Mag Article
  590. Kasparov,G - Chiburdanidze,M
  591. Baku, 1980
  592. 1.d4 Nf6 2.c4 g6 3.Nc3 Bg7 4.e4 d6 5.Nf3 0-0 6.Be2 e5 7.Be3 Qe7
  593. 8.d5 Ng4 9.Bg5 f6 10.Bh4 h5 11.h3 Nh6 12.Nd2 c5 13.Nf1 Nf7 14.g4
  594. hxg4 15.Bxg4 g5 16.Bxc8 Rxc8 17.Ne3 gxh4 18.Nf5 Qd8 19.Qg4 Ng5
  595. 20.Nxh4 Rc7 21.Nf5 a6 22.h4 Nh7 23.Rg1 Qf8 24.Ke2 Ra7 25.a4 b6
  596. 26.Qh5 Kh8 27.Rg6 Rd7 28.Rag1 Rab7 29.Qg4 Rbc7 30.Rg2 Rb7 31.Kf1
  597. Ra7 32.Kg1 Rf7 33.Ne2 Qc8 34.f4 b5 35.axb5 axb5 36.cxb5 Rab7
  598. 37.h5 Nf8 38.Qh3 Nxg6 39.hxg6+ Kg8 40.gxf7+ Kf8
  599.                            1-0
  600.  
  601.      If your text file contains games in this format, select '4'
  602. from the EXTRACT main menu.
  603.  
  604.  
  605.  
  606.  
  607. D. Running EXTRACT.EXE
  608.      When running the program, you will be presented with a menu
  609. of options.  To extract game files, choose the option which
  610. matches the format of the games in the text file.  Then, the
  611. program will ask you to specify the source file (including
  612. directory) and target file.  The target file that EXTRACT writes
  613. will hopefully be suitable for extraction by CHESSEDT.
  614.  
  615.      NOTE #1:  watch for games with more than 100 moves; CHESSEDT
  616. has trouble reading these, and you could get an error.  If in
  617. doubt, go into the target file, search for games with more than
  618. 100 moves, and either delete them or put extra moves between the
  619. annotation delimiters.
  620.  
  621.      NOTE #2:  EXTRACT.EXE has a simple routine which tries to
  622. find the date in the tournament heading.  At present, it will
  623. only recognize a full year.  For instance, if the text file chess
  624. game lists the tournament as "Linares 1990", then 1990 will
  625. appear in the CHESSEDT file as the date (in addition to appearing
  626. in the tournament name).   However, EXTRACT.EXE will not
  627. recognize partial year citations, like "Linares '90".  
  628.      Also, the present program will only recognize years within
  629. the 20th century.
  630.  
  631.      NOTE #3:  the pre-extraction routines are PICKY!  If some of
  632. the chess games in your text file deviate from the format you
  633. have specified, you will most likely wind up with an error.  So
  634. be sure to quickly review your text file beforehand to catch any
  635. incongrous games.
  636.  
  637.  
  638. D.  After Extraction
  639.      After extracting games with CHESSEDT.EXE, you might run
  640. option 3 on the EXTRACT main menu (post-extraction utility). 
  641. This will make sure that the result was recorded.  Sometimes
  642. CHESSEDT has trouble finding the result.  The post-extraction
  643. utility will search game files, and if the result is found in an
  644. annotation,  it will also be recorded in the CHESSEDT file's
  645. internal heading. Since the pre-extraction routines put results
  646. in annotations,  it is a good idea to run POSTEX on the games
  647. after they have  been extracted by CHESSEDT.
  648.  
  649.      When run, the post-extraction routine will ask for a
  650. directory to look in.  As usual, be sure to include the drive,
  651. colon, and the directory with leading and trailing slashes, ie
  652. "A:\GAMES\".  Then the program will ask for a filespec.  Type in
  653. a file name (with DOS wildcards, if desired) and POSTEX will
  654. place the result of the game from annotation to heading of the
  655. matching file (or files).  Usually, the filespec will be
  656. something like "*.GAM", to specify all game files in that
  657. directory.
  658.  
  659.  
  660.  
  661. VI. FLNM.EXE
  662.  
  663. A. Overview
  664.      Since CHESSEDT's games are each stored as a separate file,
  665. the user may find it convenient to have some file-oriented
  666. utilities to help organize his/her collection of games.  To this
  667. end, FLNM contains three interesting utilities:
  668.      FLNM1 will take the first four letters of the opening and
  669. place it in the first four spaces of the file name.  Good for
  670. naming files according to their opening!
  671.      FLNM2 will renumber a range of games sequentially, using the
  672. last four spaces of the file name.  This can be used to refer to
  673. games by their number, which is particularly useful in an opening
  674. database where files have similar names.
  675.      FLNM3 will transpose the first four letters of the file name
  676. with the last four letters.  Since CHESSEDT doesn't need a full
  677. file name to open a game file, users often only include a partial
  678. name, such as "Mark".  In this case, CHESSEDT opens the first
  679. game file it finds where the first four letters are "Mark". 
  680. Naturally, in an opening database, it may be useful to bring the
  681. number of the file (if the last four letters in the file name are
  682. a number) to the front.  That way, if you want to view game #45,
  683. you can just enter 0045 when CHESSEDT prompts you for a file
  684. name.
  685.  
  686. B. Using FLNM.EXE
  687.      To use FLNM1, FLNM2, or FLNM3, type 1,2, or 3 at the main
  688. menu of FLNM.EXE.
  689.      In each case, the program will ask for the directory to look
  690. in (remember drive and backslashes!) and a filespec.  As usual,
  691. the filespec may include DOS wildcards if you wish to affect a
  692. number of files at once.
  693.      The program FLNM2 will also ask for a starting number.  The
  694. default is to start numbering sequentially at 1.
  695.  
  696.  
  697.  
  698.  
  699.  
  700. APPENDIX:  Autokey Opening Codes
  701.    These openings are already provided in OPENING.DAT and are
  702. recognized by AUTOKEY.
  703.  
  704. IRR 01:  King's Pawn Game
  705. IRR 02:  Double King's Pawn Game
  706. IRR 03:  Queen's Pawn Game
  707. IRR 04:  Double Queen's Pawn Game
  708. KGD 00:  King's Gambit Declined
  709. KGA 00:  King's Gambit Accepted
  710. KBG 00:  King's Bishop Gambit
  711. FCG 00:  Falkbeer Countergambit
  712. VIE 00:  Vienna Game
  713. RUY 00:  Ruy Lopez
  714. RUY 01:  Ruy Lopez - Classical
  715. RUY 02:  Ruy Lopez - Berlin Defense
  716. RUY 03:  Ruy Lopez - Cozio Defense
  717. RUY 04:  Ruy Lopez - Bird's Defense
  718. RUY 05:  Ruy Lopez - Schliemann Defense
  719. RUY 06:  Ruy Lopez - Old Steinitz
  720. RUY 07:  Ruy Lopez - g6 Variation
  721. RUY 08:  Ruy Lopez - Exchange Variation
  722. RUY 09:  Ruy Lopez - Fianchetto
  723. RUY 10:  Ruy Lopez - Breyer
  724. RUY 11:  Ruy Lopez - Smyslov
  725. RUY 12:  Ruy Lopez - Chigorin
  726. RUY 13:  Ruy Lopez - Marshall Attack
  727. RUY 14:  Ruy Lopez - Open Defense
  728. RUY 15:  Ruy Lopez - Modern Steinitz
  729. THR 00:  Three Knights' Game
  730. FOR 00:  Four Knights' Game
  731. GIU 00:  Giuoco Piano
  732. GIU 01:  Giuoco Piano - Moller Attack
  733. GIU 02:  Giuoco Piano - "Pianissimo"
  734. GIU 03:  Giuoco Piano - Evans Gambit
  735. TWO 00:  Two Knights
  736. TWO 01:  Two Knights - Main Line
  737. TWO 02:  Two Knights - Wilkes-Barre
  738. TWO 03:  Two Knights - Max Lange Attack
  739. SCO 00:  Scotch Game
  740. SCO 01:  Scotch Gambit
  741. GOR 00:  Goring Gambit
  742. PON 00:  Ponziani's Opening
  743. PET 00:  Petrov's Defense
  744. PHI 00:  Philidor's Defense
  745. PHI 01:  Philidor's Defense - Hanham
  746. LAT 00:  Latvian Gambit
  747. BIS 00:  Bishop's Opening
  748. CEN 00:  Center Game
  749. DAN 00:  Danish Gambit
  750. HUN 00:  Hungarian Defense
  751. QPC 00:  Queen's Pawn Counter Gambit
  752. ALA 00:  Alapin's Opening
  753. ALE 00:  Alekhine
  754. ALE 01:  Alekhine - Modern Variation
  755. ALE 02:  Alekhine - Exchange Variation
  756. ALE 03:  Alekhine - Four Pawns Attack
  757. ALE 04:  Alekhine - Two Pawns Attack
  758. CAR 00:  Caro-Kann
  759. CAR 01:  Caro-Kann - Main Line
  760. CAR 02:  Caro-Kann - Classical
  761. CAR 03:  Caro-Kann - Nimzowitsch
  762. CAR 04:  Caro-Kann - Advance
  763. CAR 05:  Caro-Kann - Two Knights
  764. CAR 06:  Caro-Kann - Panov-Botvinnik
  765. CAR 07:  Caro-Kann - Exchange
  766. CAR 08:  Caro-Kann - Fantasy
  767. FRE 00:  French
  768. FRE 01:  French - Classical
  769. FRE 02:  French - Alekhine-Chatard
  770. FRE 03:  French - Burn
  771. FRE 04:  French - Maccutcheon
  772. FRE 05:  French - Steinitz
  773. FRE 06:  French - Rubinstein
  774. FRE 07:  French - Winawer
  775. FRE 08:  French - Tarrasch
  776. FRE 09:  French - Tarrasch (Guimard Var)
  777. FRE 10:  French - Exchange
  778. FRE 11:  French - Advance
  779. FRE 12:  French - Tchigorin
  780. FRE 13:  French - Two Knights'
  781. FRE 14:  French - King's Indian Attack
  782. SIC 00:  Sicilian
  783. SIC 01:  Sicilian - Najdorf
  784. SIC 02:  Sicilian - Najdorf Poisoned Pn
  785. SIC 03:  Sicilian - Najdorf Polugaevsky
  786. SIC 04:  Sicilian - Scheveningen
  787. SIC 05:  Sicilian - Scheveningen
  788. SIC 06:  Sicilian - Scheveningen Keres
  789. SIC 07:  Sicilian - Dragon
  790. SIC 08:  Sicilian - Dragon Yugoslav
  791. SIC 09:  Sicilian - Dragon Classical
  792. SIC 10:  Sicilian - Dragon Levenfish
  793. SIC 11:  Sicilian - Accelerated Dragon
  794. SIC 12:  Sicilian - Taimanov
  795. SIC 13:  Sicilian - Paulsen
  796. SIC 14:  Sicilian - Four Knights
  797. SIC 15:  Sicilian - Counter Attack
  798. SIC 16:  Sicilian - Lowenthal
  799. SIC 17:  Sicilian - Pelikan
  800. SIC 18:  Sicilian - Richter-Rauzer
  801. SIC 19:  Sicilian - Boleslavsky
  802. SIC 20:  Sicilian - Velimirovic
  803. SIC 21:  Sicilian - Sozin
  804. SIC 22:  Sicilian - Closed
  805. SIC 23:  Sicilian - Gran Prix
  806. SIC 24:  Sicilian - Morra Gambit
  807. SIC 25:  Sicilian - Nimzowitsch
  808. SIC 26:  Sicilian - Wing Gambit
  809. SIC 27:  Sicilian - Keres
  810. PIR 00:  Pirc
  811. PIR 01:  Pirc - Austrian
  812. PIR 02:  Pirc - Classical
  813. PIR 03:  Pirc - Byrne
  814. PIR 04:  Pirc - Fianchetto
  815. PIR 05:  Pirc - f3 System
  816. MOD 00:  Modern Defense
  817. CCD 00:  Center Counter Defense
  818. NIM 00:  Nimzowitsch Defense
  819. SAI 00:  St. George
  820. BAS 00:  Basman Defense
  821. OWE 00:  Owen's Defense
  822. QGD 00:  Queen's Gambit
  823. QGD 01:  QGD - Orthodox
  824. QGD 02:  QGD - Petrosian
  825. QGD 03:  QGD - Cambridge Springs
  826. QGD 04:  QGD - Lasker's Defense
  827. QGD 05:  QGD - Tartakower Variation
  828. QGD 06:  QGD - Exchange Variation
  829. QGD 07:  QGD - Classical
  830. QGD 08:  QGD - Ragozin
  831. QGD 09:  QGD - Semi-Tarrasch
  832. QGD 10:  QGD - Tarrasch
  833. QGD 11:  QGD - Tarrasch Rubinstein
  834. QGD 12:  QGD - Tarrasch Swedish Var.
  835. QGD 13:  QGD - Tarrasch Marshall Gambit
  836. QGD 14:  QGD - Tarrasch Von Hennig Gmbt
  837. QGD 15:  QGD - Chigorin's Defense
  838. QGD 16:  QGD - Albin Counter Gambit
  839. QGA 00:  Queen's Gambit Accepted
  840. QGA 01:  QGA - Main Line
  841. SLA 00:  Slav
  842. SLA 01:  Semi-Slav Meran
  843. SLA 02:  Semi-Slav - Romih Variation
  844. SLA 03:  Semi-Slav Anti-Meran
  845. SLA 04:  Slav Czech
  846. SLA 05:  Slav Exchange
  847. SLA 06:  Slav Exchange - Marshall Gambit
  848. SLA 07:  Slav Exchange - Abrahams
  849. BDG 00:  Blackmar-Diemer Gambit
  850. VER 00:  Veresov Attack
  851. QBA 00:  Queen's Bishop Attack
  852. TOR 00:  Torre Attack
  853. RUT 00:  Ruth-Trompowski Attack
  854. STO 00:  Stonewall Variation
  855. COL 00:  Colle System
  856. KFD 00:  King's Fianchetto Defense
  857. POL 00:  Polish Defense
  858. QKD 00:  Queen's Knight Defense
  859. BLU 00:  Blumenfeld Counter Gambit
  860. BUD 00:  Budapest Defense
  861. BUD 01:  Budapest Defense - Fajarowicx
  862. DUT 00:  Dutch Defense
  863. DUT 01:  Dutch Defense - Leningrad
  864. DUT 02:  Dutch Defense - Classical
  865. DUT 03:  Dutch Defense - Staunton Gambt
  866. QIN 00:  Queen's Indian
  867. QIN 01:  Queen's Indian
  868. QIN 02:  Queen's Indian - Petrosian
  869. BOG 00:  Bogo-Indian Defense
  870. NID 00:  Nimzo-Indian
  871. NID 01:  Nimzo-Indian - Classical
  872. NID 02:  Nimzo-Indian - Milner-Barry
  873. NID 03:  Nimzo-Indian - Rubinstein
  874. NID 04:  Nimzo-Indian - Gligoric Var.
  875. NID 05:  Nimzo-Indian - Fischer Var.
  876. NID 06:  Nimzo-Indian - Hubner System
  877. NID 07:  Nimzo-Indian - Saemisch
  878. NID 08:  Nimzo-Indian - Leningrad
  879. NID 09:  Nimzo-Indian - Spielman Var.
  880. CAT 00:  Catalan
  881. CAT 01:  Catalan - Open Variation
  882. CAT 02:  Catalan - Classical
  883. CAT 03:  Catalan - Closed Variation
  884. GIN 00:  Grunfeld Defense
  885. GIN 01:  Grunfeld Defense - Exchange
  886. GIN 02:  Grunfeld Defense - Classical
  887. GIN 03:  Grunfeld Defense - Smyslov
  888. GIN 04:  Grunfeld Defense - Prins Var.
  889. GIN 05:  Grunfeld Defense - NeoGrunfeld
  890. KIN 00:  King's Indian
  891. KIN 01:  King's Indian - Classical
  892. KIN 02:  King's Indian - Samisch
  893. KIN 03:  King's Indian - Samisch Orthod
  894. KIN 04:  King's Indian - Samisch Panno
  895. KIN 04:  King's Indian - Fianchetto
  896. KIN 05:  King's Indian - Averbakh
  897. KIN 06:  King's Indian - Four Pawns
  898. OLD 00:  Old Indian Defense
  899. BEN 00:  Benoni
  900. BEN 01:  Benoni - Main Line
  901. BEN 02:  Benoni - Knight's Toure
  902. BEN 03:  Benoni - Four Pawns
  903. BEN 04:  Benoni - Mikenas Attack
  904. BEN 05:  Benoni - Taimanov's Variation
  905. BEN 06:  Czech Benoni
  906. BEN 07:  Old Benoni
  907. BKG 00:  Benko Gambit
  908. ENG 00:  English
  909. ENG 01:  English - Sicilian Reversed
  910. ENG 02:  English - Four Knights
  911. ENG 03:  English - Bremen
  912. ENG 04:  English - Keres
  913. ENG 05:  English - Closed
  914. ENG 06:  English - Symmetrical
  915. ENG 07:  English - Symm. Four Knights
  916. ENG 08:  English - Hedgehog
  917. ENG 09:  English - Rubinstein/Botvinnik
  918. ENG 10:  English - Ultra-Symmetrical
  919. ENG 11:  English - Asymmetrical Var.
  920. RET 00:  Reti
  921. RET 01:  Reti - Barcza
  922. RET 02:  Reti - Benoni Reversed
  923. RET 03:  Reti Accepted
  924. RET 04:  Reti - London System
  925. RET 05:  Reti - Neo-Catalan
  926. KIA 00:  King's Indian Attack
  927. KIA 01:  King's Indian Attack
  928. GRR 00:  Grunfeld Reversed
  929. NIA 00:  Nimzowitsch-Larsen Attack
  930. NIA 01:  Nimzowitsch-Larsen Attack
  931. PDD 00:  Polish Defense Deferred
  932. LIS 00:  Lisitsin Gambit
  933. KFO 00:  Benko's Opening
  934. LAR 00:  Larsen's Opening
  935. BIR 00:  Bird's Opening
  936. FRO 00:  From's Gambit
  937. GRO 00:  Grob's Attack
  938. DUN 00:  Dunst
  939. SOK 00:  Sokolsky Opening
  940.  
  941.